//
//  OrderCell.swift
//  旅航ios
//
//  Created by tulip on 2021/5/6.
//

import UIKit

class OrderCell: UITableViewCell {

    var fromCtiy:String!
    var toCity:String!
    var sendDic:Dictionary<String,Any>!
    
    @IBOutlet weak var orderBtn: UIButton!
    @IBOutlet weak var restTag: UILabel!
    @IBOutlet weak var topTagView: UIView!
    @IBOutlet weak var topTabLab: UILabel!
    @IBOutlet weak var tip: UILabel!
    @IBOutlet weak var type: UILabel!
    @IBOutlet weak var price: UILabel!
    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
        
        topTagView.backgroundColor=UIColor.init(hexString: "ff6635")
        orderBtn.backgroundColor=UIColor.init(hexString: "65a0ff")
        orderBtn.layer.cornerRadius=7
      //  restTag=gradientColor(colo1: "ff8e4a", colo2: "ff6635", view: restTag, width: 31) as! UILabel
        
        restTag.layer.cornerRadius=3
        restTag.layer.masksToBounds=true
        
        self.backgroundColor=UIColor.init(hexString: "f2f1f6")
        
    }

    override func setSelected(_ selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)
        self.selectionStyle = .none

        // Configure the view for the selected state
    }
    
    @IBAction func order(_ sender: Any) {
        
        let vc=OrderPostVC.init()
        vc.fromCtiy=fromCtiy
        vc.toCity=toCity
        vc.sendDic=sendDic
        getCurrentVc().navigationController?.pushViewController(vc, animated: true)
    }
}
